namespace Brjnk.Maps.Downloader
{
    using System;

    public class DownloadTaskUpdater
    {
        public DownloadTaskUpdater(Action<DownloadTaskState> updateState,
            Action<DownloadTaskPriority> updatePriority,
            Action<long> updateTotalBytes,
            Action<long> updateReceivedBytes,
            Action<byte[]> updateData,
            Action<Exception> updateException,
            Action raiseCompleted)
        {
            this.updateState = updateState;
            this.updatePriority = updatePriority;
            this.updateTotalBytes = updateTotalBytes;
            this.updateReceivedBytes = updateReceivedBytes;
            this.updateData = updateData;
            this.updateException = updateException;
            this.raiseCompleted = raiseCompleted;
        }

        public readonly Action<DownloadTaskState> updateState;
        public readonly Action<DownloadTaskPriority> updatePriority;
        public readonly Action<long> updateTotalBytes;
        public readonly Action<long> updateReceivedBytes;
        public readonly Action<byte[]> updateData;
        public readonly Action<Exception> updateException;
        public readonly Action raiseCompleted;
    }
}